<template>
	<div class="copyright-content">
		<div id="copy_right_content">
			<div class="content-left">
				<leftMenu @changeLeftMenu="changeMenu" :isActive="isActive" :Menulists="Menulists"></leftMenu>
			</div>
			<div class="content-right">
				<rightContent :isActive="isActive"></rightContent>
			</div>
		</div>
	</div>
</template>

<script>
	//获取浏览器链接中的参数
	import utils from '../../assets/js/utils.js'
	import leftMenu from "./leftMenu/leftMenu";
	import rightContent from "./rightContent/rightContent";
	export default {
		name: "copyRight",
		components: {
			leftMenu,
			rightContent
		},
		data() {
			return {
				//左侧菜单默认选中状态
				isActive: '',
				Menulists: [{
						rightName: "内容自动接入"
					},
					{
						rightName: "版权内容仓库"
					},
					{
						rightName: "著作权证书管理"
					},
					{
						rightName: "著作权代办管理"
					}
				]
			};
		},
		methods: {
			
			//监听自组建的菜单切换
			changeMenu(value) {
				console.log("value=" + value);
				this.isActive = value;
			},
		},

		beforeMount: function() {
			
		},
		mounted: function() {
			console.log("this.isActive1="+this.isActive)
			this.isActive = this.$route.query.activeStatus;
			console.log("this.isActive="+this.isActive)
			
// 			this.$get('/platform/infos')
//       .then((response) => {
//         console.log("11111111="+response)
//       })
		},
		
		watch:{
			// 路由监听
			$route(){
        this.isActive = this.$route.query.activeStatus;
				console.log("this.isActive="+this.isActive)
      },
			isActive(val, oldVal){
            console.log("b.c: "+val, oldVal);
						this.isActive = val;
        }
		}
	};
</script>

<style scoped="scoped">
	@import "./copyRight.css";
</style>
